﻿#include "fy4taskoptimization.h"
#include <QAction>
#include <QDebug>
#include "Frame/imainframeservice.h"
#include "taskoptimizationframe.h"

void FY4TaskOptimization::start(IBundleContext::Ptr context)
{
    IServiceReference reference= context->getServiceReference<IMainFrameService>();

    if(reference){
        IMainFrameService *hello = context->getService<IMainFrameService>(reference,NULL);
        hello->addFrameCenterWidget(new TaskOptimizationFrame());
    }
}

void FY4TaskOptimization::stop(IBundleContext::Ptr context)
{
    Q_UNUSED(context)
}

void FY4TaskOptimization::testActionSlot()
{
    qDebug()<<tr("this is test action function in bundle FY4TaskOptimization");
}


//Qt4
#if(QT_VERSION < QT_VERSION_CHECK(5, 0, 0))
Q_EXPORT_PLUGIN2(FY4TaskOptimizationHMP, FY4TaskOptimization)
#endif
